﻿using UnityEngine;
using System.Collections;

public class collision : MonoBehaviour {

	public GameObject obj1;
	public GameObject obj2;

	// Use this for initialization
	void Start () {
	
	}
	
	// Update is called once per frame
	void Update () {
		if (Vector3.Distance(obj1.transform.position, obj2.transform.position) < 3)
		{
			//do something here
		}
	}
}
